# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Hugo Osvaldo Barrera <hugo@barrera.io>
# Contributor: Daniel M. Capella <polycitizen@gmail.com>
# Contributor: Hugo Osvaldo Barrera <hugo@barrera.io>
# Contributor: Limao Luo <luolimao+AUR@gmail.com>
# Contributor: Jeremy Sands <cto@jeremysands.com>

pkgname=python-parsedatetime
pkgver=2.6
pkgrel=6
pkgdesc="Parse human-readable date/time strings."
arch=('any')
license=('Apache')
url='https://github.com/bear/parsedatetime'
depends=('python-future')
makedepends=('python-setuptools')
checkdepends=('python-pytest-runner')
source=("$pkgname-$pkgver.tar.gz::https://github.com/bear/parsedatetime/archive/v$pkgver.tar.gz")
sha512sums=('ed7649feb8773fdb33d609ef0abe4d20f555744bd70e9766aba6b9a79d8415c7e2efea1d7ef5c6b5906f3bc90bff124ef92992ce17d83fe70575da2db918e543')

build() {
  cd parsedatetime-$pkgver
  python setup.py build
}

check() {
  cd parsedatetime-$pkgver
  python setup.py pytest
}

package() {
  cd parsedatetime-$pkgver
  python setup.py install --root="$pkgdir" --optimize=1
}
